<template>
  <div>加密工具</div>
  <div>
    <Button @click="encrypt">加密</Button>
    <Button @click="decrypt">解密</Button>
  </div>
</template>

<script setup lang="ts">
import { Api } from '@/types/Api'
import { Tools } from '@/types/Tools'
import {} from 'naive-ui'
import Button from 'naive-ui/es/button/src/Button'

const encrypt = () => {
  Api.get(
    `/tools/encrypt`,
    {
      text: 'hello world',
    },
    (data) => {
      console.log(data)
    },
  )
}

const decrypt = () => {
  Api.get(
    `/tools/decrypt`,
    {
      text: '123456',
    },
    (data) => {
      console.log(data)
    },
  )
}
</script>

<style scoped></style>
